import request from '../util/request'

export const getShopList = (data) => {
    return request({
        url:'/shopList',
        method:'post',
        data:data
    })
}

export const getDetail = (id) => {
    return request({
        url:`/shopDetail?id=${id}`,
        method:'get'
    })
}

export const getSearch = (key) => {
    return request({
        url:`/search?key=${key}`,
        method:'get'
    })
}

export const orderPrice = (key) => {
    return request({
        url:`/search_orderPrice?key=${key}`,
        method:'get'
    })
}

export const remark = (data) => {
    return request({
        url:'/submitRemark',
        method:'post',
        data:data
    })
}
export const remarkList = (id) => {
    return request({
        url:`/remarkList?shop_id=${id}`,
        method:'get'
    })
}

// 获取token
export function getToken() {
    return request({
        url:'/getToken',
        method:'get'
    })
}

// 分类
export function getCatogory(data) {
    return request({
        url:'/catogory',
        method:'post',
        data
    })
}
